import { ref, computed,reactive } from 'vue'
import { defineStore } from 'pinia'
import { ro } from 'element-plus/es/locale/index.mjs'

export const useCounterStore = defineStore('counter', () => {
  const count = ref(0)
  const doubleCount = computed(() => count.value * 2)
  const MapPiain=reactive({
    userName:'',
    userPass:'',
    userId:0,
    roleId:0,
    roleName:'',
    userNickname:'',
  })
  function increment() {
    count.value++
  }

  return { count, doubleCount, increment ,MapPiain}
},{persist:true})
